import request from '@/utils/request'
const depart = {
  getDepartmentListAPI: function (params) {
    return request({
      url: '/sys/department/list',
      method: 'post',
      data: params
    })
  },
  addDepartmentAPI: function (params) {
    return request({
      url: '/sys/department/add',
      method: 'post',
      data: params
    })
  },
  updateDepartmentAPI: function (params) {
    return request({
      url: '/sys/department/update/' + params.departmentCode,
      method: 'put',
      data: params
    })
  },
  deleteDepartmentAPI: function (params) {
    return request({
      url: '/sys/department/delete/' + params.departmentCode,
      method: 'delete'
    })
  },
  getDepartmentPositionAPI: function (params) {
    return request({
      url: '/sys/department/position/list',
      method: 'post',
      data: params
    })
  }
}
export default depart
